package com.yingxin.yxerp.module.common;

public enum StoppageType {

    SC_TG("1", "生产停工"),

    JX_TG("2", "机修停工"),

    WJH_TG("3", "无计划停工"),

    QT_TG("4", "其它原因");

    private String type;

    private String typeName;

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getTypeName() {
        return typeName;
    }

    public void setTypeName(String typeName) {
        this.typeName = typeName;
    }

    StoppageType(String type, String typeName) {
        this.type = type;
        this.typeName = typeName;

    }

    public static StoppageType getEnum(String type) {
        for (StoppageType i : StoppageType.values()) {
            if (i.getType().equals(type)) {
                return i;
            }
        }
        return null;
    }

}